home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d15 / gqmail.arc / QMAIL.XWS < prev   
Text File  |  1990-12-09  |  2KB  |  90 lines

  1. /* 
  2. Crosstalk for Windows MarkMail Qmail Automator
  3. version 2.4 11/27/1990
  4. */
  5.  
  6. /*
  7. If you are using Qmail, this script assumes that you have
  8. The extended prompts on
  9. */
  10. STRING RepName, QwkName, DirRep, DirQwk, SaveQwk, MailCmd, Cmd
  11.  
  12. MailCmd is Arg(2) + " " + Arg(3)
  13. Cmd is Arg(1) + " " + Arg(2) + " " + Arg(3)
  14. If UpCase(Arg(1)) is "MAIL" then Mail is True else Mail is False
  15. --WE'RE DOING MAIL
  16.  
  17. RepName is NAME+".REP"
  18. QwkName is NAME+".QWK"
  19. DirRep is DirFil+"\"+RepName
  20. DirQwk is DirFil+"\"+QwkName
  21. SaveQwk is DirFil+"\"+inject(QwkName,"1",1)
  22. --SET UP FILE NAMES
  23.  
  24. -- The language prompt on some boards 
  25. wait 10 seconds for '=no?' : If TimeOut then GoTo WatchLoop
  26.     else reply 'n q'
  27.  
  28. --Minimize
  29. --ENABLE THE ABOVE AFTER YOU'VE DETERMINED THAT THE SCRIPT WORKS
  30.  
  31. LABEL WatchLoop
  32. reply
  33. --THE ABOVE REPLY IS SO THAT YOU CAN ACTUALLY RUN THE SCRIPT AFTER
  34. --YOU HAVE LOGGED ONTO A PCBOARD.
  35. while online
  36. watch for
  37.       'first name?'   : wait 5 ticks : reply UserID+ " " + Password
  38.       '=no?',
  39.       'tinue?',
  40.       'tinue:',
  41.       'stop?',
  42.       '(NS)?',
  43.       'use (Enter)=no change?',
  44.       'More?'         : wait 5 ticks : reply
  45.       '=yes?'  : wait 5 ticks : reply "N"
  46.       'Check your mail' : reply "N"
  47. --FOR THE QUICK LOGON FOUND ON SOME PCBOARDS.
  48.       '(S)ystem, (Enter)=' : If Mail then Reply MailCmd else reply Cmd:... 
  49.                Alarm : Halt
  50. --The normal main board prompt or confernce prompt
  51.       'Conference Command?',
  52.       'Board Command? '  : If Mail then...
  53.                 Reply MailCmd :...
  54.                 Wait 10 Ticks else Reply Cmd : Alarm : Halt
  55. -- The mail prompts
  56.         'MarkMail Command?',
  57.     '<COMMAND>':  Reply "D" : Goto GetPacket
  58.   endwatch
  59.  wend
  60.  
  61. LABEL GetPacket
  62. Watch for
  63.     '[Y]es, [N]o, [G]oodbye When Done? ',
  64.     '<DLASK>':  Reply "Y" :    GoSub DoFiles : Goto SendFiles 
  65.     '<NO TRANSFER>' : Wait 3 : Goto SendFiles 
  66. endwatch
  67.  
  68. LABEL DoFiles
  69.     If Exists(SaveQwk) then Delete SaveQwk
  70.     If Exists(DirQwk) then Rename DirQwk,SaveQwk 
  71.     Message "Renaming old QWK"
  72.     Watch for
  73.         '(Ctrl-X) Aborts Transfer':  Receive QwkName : Alarm :  Wait  for 'Command'
  74.         '<DOWNLOAD>':  Receive QwkName : Alarm :  Wait  for '<COMMAND>'
  75.     endwatch
  76. Return
  77.  
  78. LABEL SendFiles
  79. If exists(DirRep) then{
  80.          Reply "U" 
  81.          Wait 5 ticks 
  82.          Send RepName 
  83.          Delete DirRep
  84.          Message "Deleting reply file..."
  85.         Wait 10 For 'Command' : Reply "G" : Halt
  86.          }
  87. else Reply "G" :  Halt
  88.  
  89.  
  90. end